Overview
A horizontal or vertical separator line. The visual appearance of this
separator can be controlled via CSS. A horizontal separator occupies the
full horizontal space allocated to it (less padding), and a vertical
separator occupies the full vertical space allocated to it (less padding).
The hpos
and vpos
variables determine how the
separator is positioned in the other dimension, for example, how a horizontal
separator is positioned vertically within its allocated space.
The separator is horizontal by default.
The style-class for this control is "separator".
The separator provides two pseudo-classes "horizontal" and "vertical" which are mutually exclusive. The "horizontal" pseudo-class applies if the separator is horizontal, and the "vertical" pseudo-class applies if the separator is vertical.
The separator provides two style properties, "hpos" and "vpos". The values for these properties are the enumeration constants of the HPos and VPos classes, respectively.
Below is an example of using a separator in a VBox.
the code:
import javafx.geometry.*;
import javafx.scene.control.*;
import javafx.scene.layout.*;
VBox {
nodeHPos: HPos.CENTER
content: [
Label { text: "Above" },
Separator { },
Label { text: "Below" }
]
}
produces:
Profile: common
Script Variable Summary
access | name | type | Can Read | Can Init | Can Write | Default Value | description |
---|
Variable Summary
access | name | type | Can Read | Can Init | Can Write | Default Value | description |
---|---|---|---|---|---|---|---|
public | hpos | HPos | ![]() | ![]() | ![]() |
For vertical separators, specifies the horizontal position of the separator line within the separator control's space. ![]() |
|
public | vertical | Boolean | ![]() | ![]() | ![]() |
Specifies whether the separator should run horizontally or vertically. |
|
public | vpos | VPos | ![]() | ![]() | ![]() |
For horizontal separators, specifies the vertical position of the separator line within the separator control's space. ![]() |
Inherited Variables
javafx.scene.control.Control
access | name | type | Can Read | Can Init | Can Write | Default Value | description |
---|---|---|---|---|---|---|---|
public | skin | Skin | ![]() | ![]() | ![]() |
Skin responsible for rendering this ![]() |
|
public | tooltip | Tooltip | ![]() | ![]() | ![]() |
Set ToolTip for this control |
javafx.scene.Parent
access | name | type | Can Read | Can Init | Can Write | Default Value | description |
---|---|---|---|---|---|---|---|
protected | children | Node[] | subclass | subclass | subclass | empty |
A sequence of child ![]() |
public-read protected | needsLayout | Boolean | ![]() | subclass | subclass |
Indicates that this Node and its subnodes requires a layout pass on the next pulse. |
javafx.scene.Node
access | name | type | Can Read | Can Init | Can Write | Default Value | description |
---|---|---|---|---|---|---|---|
public | blocksMouse | Boolean | ![]() | ![]() | ![]() | false |
If ![]() |
public-read | boundsInLocal | Bounds | ![]() |
The rectangular bounds of this ![]() |
|||
public-read | boundsInParent | Bounds | ![]() |
The rectangular bounds of this ![]() |
|||
public | cache | Boolean | ![]() | ![]() | ![]() | false |
A performance hint to the system to indicate that this ![]() |
public | cacheHint | CacheHint | ![]() | ![]() | ![]() | CacheHint.DEFAULT |
Additional hint for controlling bitmap caching. ![]() |
public | clip | Node | ![]() | ![]() | ![]() | null |
Specifies a ![]() |
public | cursor | Cursor | ![]() | ![]() | ![]() | null |
Defines the mouse cursor for this ![]() |
public | disable | Boolean | ![]() | ![]() | ![]() | false |
Sets the individual disabled state of this ![]() |
public-read | disabled | Boolean | ![]() | false |
Indicates whether or not this ![]() |
||
public | effect | Effect | ![]() | ![]() | ![]() | null |
Specifies an effect to apply to this ![]() |
public-read protected | focused | Boolean | ![]() | subclass | subclass | false |
Indicates whether this ![]() |
public | focusTraversable | Boolean | ![]() | ![]() | ![]() | false |
Specifies whether this ![]() |
public-read protected | hover | Boolean | ![]() | subclass | subclass | false |
Whether or not this ![]() |
public | id | String | ![]() | ![]() | ![]() | empty string |
The id of this ![]() |
public-read protected | layoutBounds | Bounds | ![]() | subclass | subclass |
The rectangular bounds that should be used for layout calculations on
this ![]() |
|
public | layoutInfo | LayoutInfoBase | ![]() | ![]() | ![]() |
Hook for node-specific layout information used by layout containers. ![]() |
|
public | layoutX | Number | ![]() | ![]() | ![]() | 0 |
Defines the x coordinate of the translation that is added to this ![]() |
public | layoutY | Number | ![]() | ![]() | ![]() | 0 |
Defines the y coordinate of the translation that is added to this ![]() |
public | managed | Boolean | ![]() | ![]() | ![]() | true |
Defines whether or not this node's layout will be managed by it's parent. ![]() |
public | onKeyPressed | function(:KeyEvent):Void | ![]() | ![]() | ![]() |
Defines a function to be called when this |
|
public | onKeyReleased | function(:KeyEvent):Void | ![]() | ![]() | ![]() |
Defines a function to be called when this |
|
public | onKeyTyped | function(:KeyEvent):Void | ![]() | ![]() | ![]() |
Defines a function to be called when this |
|
public | onMouseClicked | function(:MouseEvent):Void | ![]() | ![]() | ![]() |
Defines a function to be called when a mouse button has been clicked
(pressed and released) on this |
|
public | onMouseDragged | function(:MouseEvent):Void | ![]() | ![]() | ![]() |
Defines a function to be called when a mouse button is pressed
on this |
|
public | onMouseEntered | function(:MouseEvent):Void | ![]() | ![]() | ![]() |
Defines a function to be called when the mouse enters this |
|
public | onMouseExited | function(:MouseEvent):Void | ![]() | ![]() | ![]() |
Defines a function to be called when the mouse exits this |
|
public | onMouseMoved | function(:MouseEvent):Void | ![]() | ![]() | ![]() |
Defines a function to be called when mouse cursor moves within
this |
|
public | onMousePressed | function(:MouseEvent):Void | ![]() | ![]() | ![]() |
Defines a function to be called when a mouse button
has been pressed on this |
|
public | onMouseReleased | function(:MouseEvent):Void | ![]() | ![]() | ![]() |
Defines a function to be called when a mouse button
has been released on this |
|
public | onMouseWheelMoved | function(:MouseEvent):Void | ![]() | ![]() | ![]() |
Defines a function to be called when the mouse scroll wheel has moved. |
|
public | opacity | Number | ![]() | ![]() | ![]() | 1.0 |
Specifies how opaque (that is, solid) the ![]() |
public-read package | parent | Parent | ![]() | null |
The parent of this ![]() |
||
public | pickOnBounds | Boolean | ![]() | ![]() | ![]() | false |
Defines how the picking computation is done for this node when
triggered by a ![]() |
public-read protected | pressed | Boolean | ![]() | subclass | subclass | false |
Whether or not the ![]() |
public | rotate | Number | ![]() | ![]() | ![]() | 0.0 |
Defines the angle of rotation about the ![]() |
public | rotationAxis | Point3D | ![]() | ![]() | ![]() | Rotate.Z_AXIS |
Defines the axis of rotation of this ![]() |
public | scaleX | Number | ![]() | ![]() | ![]() | 1.0 |
Defines the factor by which coordinates are scaled about the center of the
object along the X axis of this ![]() |
public | scaleY | Number | ![]() | ![]() | ![]() | 1.0 |
Defines the factor by which coordinates are scaled about the center of the
object along the Y axis of this ![]() |
public | scaleZ | Number | ![]() | ![]() | ![]() | 1.0 |
Defines the factor by which coordinates are scaled about the center of the
object along the Z axis of this ![]() |
public-read package | scene | Scene | ![]() | null |
The Scene that this ![]() |
||
public | style | String | ![]() | ![]() | ![]() | empty string |
A string representation of the CSS style associated with this specific Node. ![]() |
public | styleClass | String | ![]() | ![]() | ![]() | empty string |
A String identifier which can be used to logically group Nodes, specifically for an external style engine. ![]() |
public | transforms | Transform[] | ![]() | ![]() | ![]() | empty |
Defines the sequence of javafx.scene.transform.Transform objects
to be applied to this ![]() |
public | translateX | Number | ![]() | ![]() | ![]() | 0 |
Defines the x coordinate of the translation that is added to this ![]() |
public | translateY | Number | ![]() | ![]() | ![]() | 0 |
Defines the y coordinate of the translation that is added to this ![]() |
public | translateZ | Number | ![]() | ![]() | ![]() | 0 |
Defines the Z coordinate of the translation that is added to the
transformed coordinates of this ![]() |
public | visible | Boolean | ![]() | ![]() | ![]() | true |
Specifies whether this ![]() |
javafx.scene.layout.Resizable
access | name | type | Can Read | Can Init | Can Write | Default Value | description |
---|---|---|---|---|---|---|---|
public | height | Number | ![]() | ![]() | ![]() |
The ![]() |
|
public | width | Number | ![]() | ![]() | ![]() |
The ![]() |
javafx.scene.text.TextOffsets
access | name | type | Can Read | Can Init | Can Write | Default Value | description |
---|---|---|---|---|---|---|---|
public-read protected | baselineOffset | Number | ![]() | subclass | subclass |
The 'alphabetic' (or 'roman') baseline offset from the node's layoutBounds.minY location. |
Inherited Functions
javafx.scene.control.Control
- public getHFill() : Boolean
- public getHGrow() : Priority
- public getHShrink() : Priority
- public getMaxHeight() : Number
- public getMaxWidth() : Number
- public getMinHeight() : Number
- public getMinWidth() : Number
- public getPrefHeight(width: Number) : Number
- public getPrefWidth(height: Number) : Number
- public getVFill() : Boolean
- public getVGrow() : Priority
- public getVShrink() : Priority
javafx.scene.Parent
- public layout() : Void
- public lookup(id: java.lang.String) : Node
- public requestLayout() : Void
javafx.scene.Node
- public contains(localX: Number, localY: Number) : Boolean
- public contains(localPoint: Point2D) : Boolean
- public intersects(localX: Number, localY: Number, localWidth: Number, localHeight: Number) : Boolean
- public intersects(localBounds: Bounds) : Boolean
- public localToParent(localX: Number, localY: Number) : Point2D
- public localToParent(localPoint: Point2D) : Point2D
- public localToParent(localBounds: Bounds) : Bounds
- public localToScene(localX: Number, localY: Number) : Point2D
-
Transforms a point from the local coordinate space of this
Node
into the coordinate space of its javafx.scene.Scene. - public localToScene(localPoint: Point2D) : Point2D
-
Transforms a point from the local coordinate space of this
Node
into the coordinate space of its javafx.scene.Scene. - public localToScene(localBounds: Bounds) : Bounds
-
Transforms a bounds from the local coordinate space of this
Node
into the coordinate space of its javafx.scene.Scene. - public lookup(id: java.lang.String) : Node
- public parentToLocal(parentX: Number, parentY: Number) : Point2D
- public parentToLocal(parentPoint: Point2D) : Point2D
- public parentToLocal(parentBounds: Bounds) : Bounds
- public requestFocus() : Void
- public sceneToLocal(sceneX: Number, sceneY: Number) : Point2D
-
Transforms a point from the coordinate space of the Scene into the local coordinate space of this
Node
. - public sceneToLocal(scenePoint: Point2D) : Point2D
-
Transforms a point from the coordinate space of the javafx.scene.Scene into the local coordinate space of this
Node
. - public sceneToLocal(sceneBounds: Bounds) : Bounds
-
Transforms a rectangle from the coordinate space of the javafx.scene.Scene into the local coordinate space of this
Node
. - public toBack() : Void
- public toFront() : Void
- public toString() : java.lang.String
javafx.scene.layout.Resizable
- public getHFill() : Boolean
- public getHGrow() : Priority
- public getHShrink() : Priority
- public getMaxHeight() : Number
- public getMaxWidth() : Number
- public getMinHeight() : Number
- public getMinWidth() : Number
- public abstract getPrefHeight(width: Number) : Number
- public abstract getPrefWidth(height: Number) : Number
- public getVFill() : Boolean
- public getVGrow() : Priority
- public getVShrink() : Priority